#include <bits/stdc++.h>

using namespace std;
using ll = long long;

void solve() {
	int n;
	string s;
	cin >> n;
	cin >> s;

	int count0 = 0;
	vector<int> v(n);
	for (int i = 0; i < n; i++) {
		char c = s[i];
		if (c == '0') {
			v[count0++] = i + 1;
		}
	}

	cout << count0 << endl;
	for (int i = 0; i < count0; i++) {
		cout << v[i] << (i == count0 - 1 ? "\n" : " ");
	}
}

int main() {
	ios_base::sync_with_stdio(false);
	cin.tie(nullptr);
	
	int t;
	cin >> t;
	while (t-- > 0) {
		solve();
	}
	return 0;
}
